import { NgModule } from '@angular/core';
import { RouterModule, Routes } from '@angular/router';
import { WORKLOADS_ROUTE} from '../routing';
import { GitManagerComponent } from './git-manager/git-manager.component';
import { GitMonitorComponent } from './git-monitor/git-monitor.component';
import { ProjectDetailComponent } from './project-detail/project-detail.component';
import {DockerConfigComponent } from './docker-config/docker-config.component'


const GIT_ROUTE :Routes=[{
  path: '',
  component: GitManagerComponent,
  data: {
    parent: WORKLOADS_ROUTE,
  }
}
  ,
  {
      path: 'monitor',  // child route path
      component: GitMonitorComponent,  // child route component that the router renders
      data: {
        parent: WORKLOADS_ROUTE,
      }
  },
  {
    path: 'projdetail/:gitid',
    component:ProjectDetailComponent,
    data: {
      parent: WORKLOADS_ROUTE,
    }
  },
  {
    path:'dockerconfig',
    component : DockerConfigComponent,
    data: {
      parent: WORKLOADS_ROUTE,
    }
  }
  
];
@NgModule({
  imports: [RouterModule.forChild(GIT_ROUTE)],
  exports: [RouterModule]
})
export class GitRoutingModule { }
